package com.hr.runnerbuddy;

import java.util.ArrayList;

import android.content.Context;
import android.graphics.drawable.Drawable;

import com.google.android.maps.ItemizedOverlay;
import com.google.android.maps.OverlayItem;

public class KaartGebruikerLaag extends ItemizedOverlay<OverlayItem> {
   
   private ArrayList<OverlayItem> mapOverlays = new ArrayList<OverlayItem>();

   
   public KaartGebruikerLaag (Drawable defaultMarker) {
        super(boundCenter(defaultMarker));
   }
   
   public KaartGebruikerLaag (Drawable defaultMarker, Context context) {
        this(defaultMarker);
   }

   @Override
   protected OverlayItem createItem(int i) {
      return mapOverlays.get(i);
   }

   @Override
   public int size() {
      return mapOverlays.size();
   }
   
   @Override
   protected boolean onTap(int index) {
	return false;
     //
   }
   
   public void addOverlay(OverlayItem overlay) {
      mapOverlays.add(overlay);
      this.populate();
   }

}